
class locker:
	def __init__(self):
		print('locker 类型初始化');

	def start():
		print('locker.start()')

	def end():
		print('locker.end')

		
def loggin(cls):
	def warpper(func):
		def inner_warpper(*args,**kwargs):
			cls.start();
			func()
			cls.end();
		return inner_warpper;
	return warpper;


@loggin(locker)
def myfunc():
	print('myfunc')

myfunc()